package zom.zenjava.zendeploy.gui.jfx;

import javafx.concurrent.Service;
import javafx.concurrent.Task;
import zom.zenjava.zendeploy.ZenDeployManager;
import zom.zenjava.zendeploy.model.CheckForUpdateResult;

public class CheckForUpdateService extends Service<CheckForUpdateResult>
{
    protected Task<CheckForUpdateResult> createTask()
    {
        return new Task<CheckForUpdateResult>()
        {
            protected CheckForUpdateResult call() throws Exception
            {
                ZenDeployManager zenDeployManager = ZenDeployManager.getInstance();
                return zenDeployManager.checkForUpdatedApplicationProfile();
            }
        };
    }
}
